package com.botao.tip.utils;

public class RoleUtil {
    public static String getRole(int roleId) {
        String role = "";
        if (roleId == 0) {
            role = "员工";
        } else if (roleId == 1) {
            role = "管理员";
        } else if (roleId == 2) {
            role = "超级管理员";
        }
        return role;
    }

    public static int getRoleId(String role) {
        int roleId = 0;
        if ("员工".equals(role)) {
        } else if ("管理员".equals(role)) {
            roleId = 1;
        } else if ("超级管理员".equals(role)) {
            roleId = 2;
        }
        return roleId;
    }
}
